package com.alks.function.service.stockdept.pcfactorystockquery;

import com.alks.entity.data.entity.PcMtlAcc;
import com.alks.entity.data.entity.PcMtlCheck2;
import com.alks.entity.data.response.ResponseInfo;
import com.alks.function.data.dto.PcMtlCheckFinReq;
import com.alks.function.data.dto.SurfaceInMaterialReq;
import com.alks.function.data.request.stockdept.pcfactorystockwork.*;
import com.alks.function.data.vo.stock.MtlAccVo;

import javax.servlet.http.HttpServletResponse;
import java.time.LocalDateTime;
import java.util.List;

/**
 * <p>
 * 材料暂收表 服务类
 * </p>
 *
 * @author ms
 * @since 2023-08-23
 */
public interface IPcMtlCheckService {

    ResponseInfo getPurUnSentQuery(MpPurDisRequest request, int i);

    ResponseInfo getPurSentQuery(MpPurDisRequest request, int i);

    ResponseInfo sentMtlTypeQuery();

    ResponseInfo purSentAdd(List<AddPurSendRequest> request, String vendorNo, String sendNo, int slipType);

    ResponseInfo sentMtlTypeAdd(List<UserMtlTypeRequest> requests, Integer flag);

    ResponseInfo purPutStockUpdate(List<PurSentRequest> request);

    ResponseInfo purStockUpdate(String recNo);

//    ResponseInfo purUnSentQtyUpdate(List<PurUnSendQtyRequest> request);

    ResponseInfo purSentRemark(List<PurSentRemarkRequest> request);

    ResponseInfo purSentDelete(List<PurSentRequest> request);

    ResponseInfo purStockBack();

    ResponseInfo getPcMtlCheckFin(PcMtlCheckFinReq req);

    ResponseInfo getPcMtlCheckFinDetail(String recNo);

    ResponseInfo getSdBomFitSub(String mtlNo);

    ResponseInfo optionPcMtlCheck(List<PcMtlCheck2> list, String choose);

    ResponseInfo clickPcMtlCheck(List<PcMtlCheck2> list, String remark);

    ResponseInfo savePcMtlCheck(List<PcMtlCheck2> list);

    ResponseInfo getDetails();

    ResponseInfo getSurfaceMtl(SurfaceInMaterialReq req);

    ResponseInfo getUnitPrice(List<PcMtlCheck2> list);

    void mtlInvCount(List<MtlAccVo> read);

    /**
     * 录入材料库存，没有则新增
     * @param accList 待入库数据
     */
    void mtlAccIn(List<PcMtlAcc> accList);

    /**
     * 发货日期单号更新
     *
     * @param id       待修改数据ID
     * @param sendDate 修改后日期
     * @param sendNo   修改后发料单号
     * @param remark 备注
     */
    void purSendUpdate(Integer id, LocalDateTime sendDate, String sendNo, String remark);

    /**
     * 删除暂收单
     * @param primaryId 主键ID
     * @param slipType 收料类型
     */
    void purSpSentDelete(String primaryId, int slipType);

    /**
     * 导出未找到的材料
     * @param read 读取到的数据
     * @param response 响应
     */
    void printMiss(List<MtlAccVo> read, HttpServletResponse response);
}
